﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.ComponentModel.DataAnnotations;

namespace XAPI.Domain
{
    public class InverseFunctionalIdentifier : XObject
    {
        /// <summary>
        /// The required format is "mailto:email address". 
        /// The local part of the email address must be URI encoded. 
        /// Only email addresses that have only ever been and will ever be 
        /// assigned to this Agent, but no others, should be used for this 
        /// property and mbox_sha1sum.
        /// </summary>
        [Key]
        public string mbox { get; set; }

        /// <summary>
        /// The SHA1 hash of a mailto URI (i.e. the value of an mbox 
        /// property). An LRS MAY include Agents with a matching hash when 
        /// a request is based on an mbox
        /// </summary>
        public string mbox_sha1sum { get; set; }

        /// <summary>
        /// An openID that uniquely identifies the Agent
        /// URI
        /// </summary>
        public string openID { get; set; }

        /// <summary>
        /// A user account on an existing system e.g. an LMS or intranet
        /// </summary>
        public AccountObject account { get; set; }

        /// <summary>
        /// Name of the actor/group. not required
        /// </summary>
        public string name { get; set; }
    }
}
